<?php

if ( isset($_POST['count']) )
{
	$i = is_numeric($_POST['count']) ? $_POST['count'] : '';
	
	if ( $i || ($i == 0) )
	{
		require_once('../../../../../wp-load.php' );
		
		$html = '';
	
		ob_start();
		?>
		<p style="margin: 0 0 30px 0;" id="provider-<?php echo $i; ?>">
			<label for="provider-name-<?php echo $i; ?>">Feed Provider:</label>
			<input type="text" id="provider-name-<?php echo $i; ?>" name="<?php echo "bs-general-options[providers][$i][name]"; ?>" value="" />
			
			<label for="provider-source-<?php echo $i; ?>">Source:</label>
			<input type="text" id="provider-source-<?php echo $i; ?>" name="<?php echo "bs-general-options[providers][$i][source]"; ?>" value="" />
			
			<a style="cursor:pointer;" id="remove-provider-<?php echo $i; ?>" class="secondary remove-provider">Remove</a>
		</p>
		<?php
		
		$html = ob_get_contents();
		ob_end_clean();
		
		echo $html;
	}
}